<?xml version="1.0" encoding="utf-8"?>
<xs:schema id="MVEVideos" targetNamespace="http://tempuri.org/MVEVideos.xsd" elementFormDefault="qualified" xmlns="http://tempuri.org/MVEVideos.xsd" xmlns:mstns="http://tempuri.org/MVEVideos.xsd" xmlns:xs="http://www.w3.org/2001/XMLSchema">
  <xs:element name="VideoList">
    <xs:complexType>
      <xs:sequence>
        <xs:element name="Video" maxOccurs="unbounded">
          <xs:complexType>
            <xs:sequence>
              <xs:element name="Title" type="xs:string" />
              <xs:element name="Image" type="xs:string" />
              <xs:element name="URL" type="xs:string" />
              <xs:element name="Description" type="xs:string" />
              <xs:element name="VideoInfo" maxOccurs="1" minOccurs="0">
                <xs:complexType>
                  <xs:sequence>
                    <xs:element name="Origin" type="xs:dateTime" nillable="true" />
                    <xs:element name="Length" type="xs:int" nillable="true" />
                    <xs:element name="Source" type="xs:string" nillable="true" />
                  </xs:sequence>
                </xs:complexType>
              </xs:element>
              <xs:element name="VideoKeyword" maxOccurs="unbounded" minOccurs="0">
                <xs:complexType>
                  <xs:sequence>
                    <xs:element name="KeywordID" type="xs:int" />
                  </xs:sequence>
                </xs:complexType>
              </xs:element>
              <xs:element name="RelationID" type="xs:int" />
            </xs:sequence>
            <xs:attribute name="VideoID" type="xs:int" />
          </xs:complexType>
        </xs:element>
        <xs:element name="Keyword" maxOccurs="unbounded">
          <xs:complexType>
            <xs:sequence>
              <xs:element name="KeywordName" type="xs:string" />
            </xs:sequence>
            <xs:attribute name="KeywordID" type="xs:int" />
          </xs:complexType>
        </xs:element>
        <xs:element name="Relation" maxOccurs="unbounded">
          <xs:complexType>
            <xs:sequence>
              <xs:element name="RelationName" type="xs:string" />
              <xs:element name="Color" type="xs:string" />
            </xs:sequence>
            <xs:attribute name="RelationID" type="xs:int" />
          </xs:complexType>
        </xs:element>
      </xs:sequence>
    </xs:complexType>
    <xs:key name="RelationKey">
      <xs:selector xpath=".//mstns:Relation" />
      <xs:field xpath="@RelationID" />
    </xs:key>
    <xs:keyref name="RelationVideo" refer="RelationKey">
      <xs:selector xpath=".//mstns:Video" />
      <xs:field xpath="mstns:RelationID" />
    </xs:keyref>
    <xs:key name="KeywordKey">
      <xs:selector xpath=".//mstns:Keyword" />
      <xs:field xpath="@KeywordID" />
    </xs:key>
    <xs:keyref name="KeywordVideoKeyword" refer="KeywordKey">
      <xs:selector xpath=".//mstns:VideoKeyword" />
      <xs:field xpath="mstns:KeywordID" />
    </xs:keyref>
  </xs:element>
</xs:schema>